#!/bin/bash

CUR_DIR=$(cd "$(dirname $0)" && pwd)
ROOT_DIR=$(dirname "$CUR_DIR")
ROOT_DIR=$(dirname "$ROOT_DIR")
ROOT_DIR=$(dirname "$ROOT_DIR")
source "$ROOT_DIR/bin/shell_func.sh"

if [ $? -ne 0 ]; then echo "Terminating..." >&2; exit 1; fi

DEBUG=1

$LUA_BIN -e "ROOT_DIR='$ROOT_DIR'; DEBUG=$DEBUG; dofile('$CUR_DIR/run_tests_func.lua'); runTests('$*')"
